import request from '@/utils/request'
export function loginInFrom(data) {
  return request.post('/auth/local', data)
}
// 获取全部数据
export function getInFrom(params) {
  return request.get('/clients', { params })
}
export function addfromdata(data) {
  return request.post('/clients', data)
}
// 获取当前用户
export function getuser() {
  return request.get('/users/me')
}
// 删除用户
export function remove(id) {
  return request.delete(`/clients/${id}`)
}
// 根据id获取指定用户
export function getassign(id) {
  return request.get(`/clients/${id}`)
}
export function editdata(data) {
  return request.put(`/clients/${data.id}`, data)
}
// 获取全部数量
export function getdataNumber() {
  return request.get(`/clients/count`)
}
// 获取经济列表
export function getagents() {
  return request.get(`/agents`)
}
